package com.example.demo01.Controller.webController;

import com.alibaba.fastjson.JSON;
import com.example.demo01.Service.webService.SelectTreeEntityService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class SelectTreeEntityController {
    //自动装配
    @Autowired
    private SelectTreeEntityService selectTreeEntityService;

    /**
     * 获取焦作市城市名称列表
     * */
    @RequestMapping("/citylist/GET/all")
    public String getCityList(){
        return JSON.toJSONString(selectTreeEntityService.getCityList());
    }

    @RequestMapping("/userinfolist/GET/all")
    public String getUserInfoSimple(){
        return JSON.toJSONString(selectTreeEntityService.getUserInfoSimple());
    }

}
